% sentence(Parse,[tho6ng, so61, ky4, thua65t, cu3a, tu3, la5nh, sharp, SJ16VSL, la2],[]).
% tho6ng so61 (ky4 thua65t) cu3a tu3 la5nh/ tu3 d9o6ng/ ma1y la5nh/ d9ie62u hoa2 sharp SJ16VSL la2

sentence(s(NP, VP))-->np(NP),vp(VP).

% cum danh tu
np(np(N_tuhoi, E, SP))-->n_tuhoi(N_tuhoi), e(E), sp(SP).

% cac tu hoi
n_tuhoi(n_tuhoi('tho6ng so61'))-->[tho6ng, so61].
n_tuhoi(n_tuhoi('tho6ng so61 ky4 thua65t'))-->[tho6ng, so61, ky4, thua65t].
n_tuhoi(n_tuhoi('tho6ng so61 ki4 thua65t'))-->[tho6ng, so61, ki4, thua65t].

% gioi tu
e(e(cu3a))-->[cu3a];[].

% san pham
sp(sp(N_sp, N))-->n_sp(N_sp), n(N).

% cac loai san pham
n_sp(n_sp('tu3 la5nh'))-->[tu3, la5nh].
n_sp(n_sp('tu3 d9o6ng'))-->[tu3, d9o6ng].
n_sp(n_sp('tu3 ma1t'))-->[tu3, ma1t].
n_sp(n_sp('ma1y la5nh'))-->[ma1y, la5nh].
n_sp(n_sp('ma1y gia85t'))-->[ma1y, gia85t].
n_sp(n_sp('d9ie62u ho2a'))-->[d9ie62u, ho2a].

n(n(N_hsx, Pron_sp))-->n_hsx(N_hsx),!,pron_sp(Pron_sp).
n(Pron_sp)-->pron_sp(Pron_sp).

% cac hang san xuat
n_hsx(n_hsx(panasonic))-->[panasonic].
n_hsx(n_hsx(daikin))-->[daikin].
n_hsx(n_hsx(lg))-->[lg].
n_hsx(n_hsx(samsung))-->[samsung].
n_hsx(n_hsx(mitsubishi))-->[mitsubishi].
n_hsx(n_hsx(electrolux))-->[electrolux].
n_hsx(n_hsx(sharp))-->[sharp].
n_hsx(n_hsx(sanyo))-->[sanyo].
n_hsx(n_hsx(hitachi))-->[hitachi].
n_hsx(n_hsx(gree))-->[gree].

pron_sp(pron_sp(H))-->[H].

% cum dong tu
vp(vp(R))-->r(R).

r(r(W_la))-->w_la(W_la).

w_la(la2)-->[la2];[].